# 打印正方形
for i in range(5):
    for j in range(5):
        print("*", end=" ")
    print()

# 打印直角三角形
for i in range(5):
    for j in range(i + 1):
        print("*", end=" ")
    print()

# 打印倒立直角三角形
for i in range(5, 0, -1):
    for j in range(i):
        print("*", end=" ")
    print()

#打印等腰三角形
for i in range(1,6):
    for j in range(5 - i):
        print(" ", end=" ")
    for j in range(2 * i - 1):
        print("*", end=" ")
    print()
